<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:p="http://primefaces.org/ui"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets">


<ui:composition template="/templates/principal.xhtml">

	<ui:define name="corpo">
		<div id="adm">
			<div id="cabecario">
				<div id="img_adm">
					<h:graphicImage library="imagens" name="administracao.png"
						height="90" />
				</div>
				<div id="info_adm">
					<h1>Administração</h1>
				</div>
				<div id="user_logado">
					<span>Bem vindo :</span>#{request.remoteUser}
				</div>
			</div>
			<div id="relogio">
				<h:graphicImage library="imagens" name="relogio.jpeg" height="300" />
			</div>
			<div id="menu">
				<h2>Menu</h2>
				<h:form prependId="false">
					<ul id="menu_adm">
						<li><h:panelGrid columns="2" cellspacing="5" cellpadding="5">
								<h:graphicImage library="imagens" name="cad.png" />
								<h:commandLink action="/admin/cad_contratado.xhtml"
									value=" Cadastrar funcionário" id="cadastrofunc" />
							</h:panelGrid></li>
						<li><h:panelGrid columns="2" cellspacing="5" cellpadding="5">
								<h:graphicImage library="imagens" name="horas.png" />
								<a href="#" id="verificahora">Verificar horas</a>
							</h:panelGrid>
						</li>

						<li><h:panelGrid columns="2" cellspacing="5" cellpadding="5">
								<h:graphicImage library="imagens" name="sair.png" />
								<h:outputLink
									onclick="document.location='#{request.contextPath}/j_spring_security_logout'"
									value="Sair">
								</h:outputLink>
							</h:panelGrid></li>
					</ul>
				</h:form>
			</div>

			<div class="tablehora" align="center" id="lista">
				<h:form>

					<h:dataTable value="#{contratanteBean.lista}" var="contratado"
						rules="rows" cellpadding="10">
						<f:facet name="caption">
						A lista corresponde a relação de funcionário cadastrados.
					</f:facet>

						<h:column>
							<f:facet name="header">Status</f:facet>
							<h:commandLink action="#">
								<h:graphicImage library="imagens" name="usuario_ativo_true.png"
									style="border:0" />
							</h:commandLink>
						</h:column>
						<h:column>
							<f:facet name="header">Código</f:facet>
								#{contratado.codigo}
						</h:column>
						<h:column>
							<f:facet name="header">Nome</f:facet>
								#{contratado.nome}
						</h:column>
						<h:column>
							<f:facet name="header">Cargo</f:facet>
								#{contratado.cargo}
						</h:column>
						<h:column>
							<f:facet name="header">Horário de trabalho</f:facet>
							#{contratado.hora_trabalho}
						</h:column>
						<h:column>
							<f:facet name="header">Status</f:facet>
							<h:commandLink action="#">
								<h:graphicImage library="imagens" name="lupa.gif"
									style="border:0" />
							</h:commandLink>
						</h:column>
						<h:column>
							<f:facet name="header">Status</f:facet>
							<h:commandLink action="#">
								<h:graphicImage library="imagens" name="editar16.png"
									style="border:0" />
							</h:commandLink>
						</h:column>
						<h:column>
							<f:facet name="header">Status</f:facet>
							<h:commandLink action="#">
								<h:graphicImage library="imagens" name="excluir16.png"
									style="border:0" />
							</h:commandLink>
						</h:column>
					</h:dataTable>
				</h:form>
			</div>

			<div class="verificahora" id="selectfunc">

				<h:form>
					<h:panelGrid>
						<h:outputLabel value="Funcionário" />
						<h:inputText value="Beji" size="50" />
						<h:outputLabel value="Mês" />
						<h:selectOneMenu value="contratanteBean.mes">
							<f:selectItem itemValue="" itemLabel="-- Selecione o mês--" />
							<f:selectItem itemValue="janeiro" itemLabel="Janeiro" />
							<f:selectItem itemValue="fereiro" itemLabel="Fevereiro" />
							<f:selectItem itemValue="marco" itemLabel="Março" />
							<f:selectItem itemValue="abril" itemLabel="Abril" />
							<f:selectItem itemValue="maio" itemLabel="Maio" />
							<f:selectItem itemValue="junho" itemLabel="Junho" />
							<f:selectItem itemValue="julho" itemLabel="Julho" />
							<f:selectItem itemValue="agosto" itemLabel="Agosto" />
							<f:selectItem itemValue="setembro" itemLabel="Setembro" />
							<f:selectItem itemValue="outubro" itemLabel="Outubro" />
							<f:selectItem itemValue="novembro" itemLabel="Novembro" />
							<f:selectItem itemValue="dezembro" itemLabel="Dezembro" />
						</h:selectOneMenu>
						
						<h:commandButton value="Consultar" action="#" styleClass="button_login"/>

					</h:panelGrid>
					
				</h:form>

			

			</div>


		</div>

	</ui:define>
</ui:composition>
</html>